home *** CD-ROM | disk | FTP | other *** search
- /*******************************************************************************
- * Copyright © 1992-1993 Mark Pilgrim *
- * *
- * This file is provided as is, and may be freely distributed unaltered. This *
- * message must accompany any copy of this file. This file may be used or *
- * modified for use for a non-commercial product provided that appropriate *
- * credit is given to the author named above. *
- * Commercial use of this source code is prohibited. *
- ******************************************************************************/
-
- #include "msg misc.h"
- #include "msg timing.h"
-
- #define CorrectTime 1
-
- void SkipalineLR(GrafPtr);
-
- /* Copy even-numbered columns starting at the left and moving right, and odd-
- numbered columns starting at the right and moving left. */
-
- void SkipalineLR(GrafPtr sourceGrafPtr)
- {
- Rect thisone,thatone;
- Boolean everyOther=FALSE;
-
- thisone.left=thisone.top=thatone.top=0;
- thisone.bottom=thatone.bottom=MAIN_WINDOW_HEIGHT;
- thisone.right=1;
- thatone.right=MAIN_WINDOW_WIDTH;
- thatone.left=MAIN_WINDOW_WIDTH-1;
-
- while (thisone.left<MAIN_WINDOW_WIDTH)
- {
- StartTiming();
- CopyBits(&(sourceGrafPtr->portBits), &(gMainWindow->portBits),
- &thisone, &thisone, 0, 0L);
- CopyBits(&(sourceGrafPtr->portBits), &(gMainWindow->portBits),
- &thatone, &thatone, 0, 0L);
- thisone.left+=2; /* left column moves right by 2 */
- thisone.right+=2;
- thatone.left-=2; /* right column moves left by 2 */
- thatone.right-=2;
- if (everyOther)
- TimeCorrection(CorrectTime);
- everyOther=!everyOther;
- }
- }